import java.io.InputStream;
import java.lang.reflect.Method;
import java.util.Properties;

public class Reflact {
    public static void main(String[] args) throws Exception {
        //
        Properties property = new Properties();
        ClassLoader classLoader = Reflact.class.getClassLoader();
        InputStream resourceAsStream = classLoader.getResourceAsStream("entity/pro.properties");

        property.load(resourceAsStream);
        String className = property.getProperty("ClassName");
        String method = property.getProperty("Method");

        Class cls = Class.forName(className);
        Object obj = cls.newInstance();
        Method m = cls.getMethod(method);
        m.invoke(obj);
    }
}